ALTER TABLE web_sales SET("foreign_key_constraints" = "(ws_bill_addr_sk) REFERENCES customer_address(ca_address_sk);(ws_bill_cdemo_sk) REFERENCES customer_demographics(cd_demo_sk);(ws_bill_customer_sk) REFERENCES customer(c_customer_sk);(ws_bill_hdemo_sk) REFERENCES household_demographics(hd_demo_sk);(ws_item_sk) REFERENCES item(i_item_sk);(ws_promo_sk) REFERENCES promotion(p_promo_sk);(ws_ship_addr_sk) REFERENCES customer_address(ca_address_sk);(ws_ship_cdemo_sk) REFERENCES customer_demographics(cd_demo_sk);(ws_ship_customer_sk) REFERENCES customer(c_customer_sk);(ws_ship_date_sk) REFERENCES date_dim(d_date_sk);(ws_ship_hdemo_sk) REFERENCES household_demographics(hd_demo_sk);(ws_ship_mode_sk) REFERENCES ship_mode(sm_ship_mode_sk);(ws_sold_date_sk) REFERENCES date_dim(d_date_sk);(ws_sold_time_sk) REFERENCES time_dim(t_time_sk);(ws_warehouse_sk) REFERENCES warehouse(w_warehouse_sk);(ws_web_page_sk) REFERENCES web_page(wp_web_page_sk);(ws_web_site_sk) REFERENCES web_site(web_site_sk)");
ALTER TABLE store SET("foreign_key_constraints" = "(s_closed_date_sk) REFERENCES date_dim(d_date_sk)");
ALTER TABLE promotion SET("foreign_key_constraints" = "(p_end_date_sk) REFERENCES date_dim(d_date_sk);(p_item_sk) REFERENCES item(i_item_sk);(p_start_date_sk) REFERENCES date_dim(d_date_sk)");
ALTER TABLE customer SET("foreign_key_constraints" = "(c_current_addr_sk) REFERENCES customer_address(ca_address_sk);(c_current_cdemo_sk) REFERENCES customer_demographics(cd_demo_sk);(c_current_hdemo_sk) REFERENCES household_demographics(hd_demo_sk);(c_first_sales_date_sk) REFERENCES date_dim(d_date_sk);(c_first_shipto_date_sk) REFERENCES date_dim(d_date_sk)");
ALTER TABLE web_site SET("foreign_key_constraints" = "(web_close_date_sk) REFERENCES date_dim(d_date_sk);(web_open_date_sk) REFERENCES date_dim(d_date_sk)");
ALTER TABLE web_page SET("foreign_key_constraints" = "(wp_access_date_sk) REFERENCES date_dim(d_date_sk);(wp_creation_date_sk) REFERENCES date_dim(d_date_sk)");
ALTER TABLE catalog_page SET("foreign_key_constraints" = "(cp_end_date_sk) REFERENCES date_dim(d_date_sk);(cp_start_date_sk) REFERENCES date_dim(d_date_sk)");
ALTER TABLE store_returns SET("foreign_key_constraints" = "(sr_addr_sk) REFERENCES customer_address(ca_address_sk);(sr_cdemo_sk) REFERENCES customer_demographics(cd_demo_sk);(sr_customer_sk) REFERENCES customer(c_customer_sk);(sr_hdemo_sk) REFERENCES household_demographics(hd_demo_sk);(sr_item_sk) REFERENCES item(i_item_sk);(sr_reason_sk) REFERENCES reason(r_reason_sk);(sr_returned_date_sk) REFERENCES date_dim(d_date_sk);(sr_return_time_sk) REFERENCES time_dim(t_time_sk);(sr_store_sk) REFERENCES store(s_store_sk)");
ALTER TABLE catalog_returns SET("foreign_key_constraints" = "(cr_call_center_sk) REFERENCES call_center(cc_call_center_sk);(cr_catalog_page_sk) REFERENCES catalog_page(cp_catalog_page_sk);(cr_item_sk) REFERENCES item(i_item_sk);(cr_reason_sk) REFERENCES reason(r_reason_sk);(cr_refunded_addr_sk) REFERENCES customer_address(ca_address_sk);(cr_refunded_cdemo_sk) REFERENCES customer_demographics(cd_demo_sk);(cr_refunded_customer_sk) REFERENCES customer(c_customer_sk);(cr_refunded_hdemo_sk) REFERENCES household_demographics(hd_demo_sk);(cr_returned_date_sk) REFERENCES date_dim(d_date_sk);(cr_returned_time_sk) REFERENCES time_dim(t_time_sk);(cr_returning_addr_sk) REFERENCES customer_address(ca_address_sk);(cr_returning_cdemo_sk) REFERENCES customer_demographics(cd_demo_sk);(cr_returning_customer_sk) REFERENCES customer(c_customer_sk);(cr_returning_hdemo_sk) REFERENCES household_demographics(hd_demo_sk);(cr_ship_mode_sk) REFERENCES ship_mode(sm_ship_mode_sk);(cr_warehouse_sk) REFERENCES warehouse(w_warehouse_sk)");
ALTER TABLE catalog_sales SET("foreign_key_constraints" = "(cs_bill_addr_sk) REFERENCES customer_address(ca_address_sk);(cs_bill_cdemo_sk) REFERENCES customer_demographics(cd_demo_sk);(cs_bill_customer_sk) REFERENCES customer(c_customer_sk);(cs_bill_hdemo_sk) REFERENCES household_demographics(hd_demo_sk);(cs_call_center_sk) REFERENCES call_center(cc_call_center_sk);(cs_catalog_page_sk) REFERENCES catalog_page(cp_catalog_page_sk);(cs_item_sk) REFERENCES item(i_item_sk);(cs_promo_sk) REFERENCES promotion(p_promo_sk);(cs_ship_addr_sk) REFERENCES customer_address(ca_address_sk);(cs_ship_cdemo_sk) REFERENCES customer_demographics(cd_demo_sk);(cs_ship_customer_sk) REFERENCES customer(c_customer_sk);(cs_ship_date_sk) REFERENCES date_dim(d_date_sk);(cs_ship_hdemo_sk) REFERENCES household_demographics(hd_demo_sk);(cs_ship_mode_sk) REFERENCES ship_mode(sm_ship_mode_sk);(cs_sold_date_sk) REFERENCES date_dim(d_date_sk);(cs_sold_time_sk) REFERENCES time_dim(t_time_sk);(cs_warehouse_sk) REFERENCES warehouse(w_warehouse_sk)");
ALTER TABLE store_sales SET("foreign_key_constraints" = "(ss_addr_sk) REFERENCES customer_address(ca_address_sk);(ss_cdemo_sk) REFERENCES customer_demographics(cd_demo_sk);(ss_customer_sk) REFERENCES customer(c_customer_sk);(ss_hdemo_sk) REFERENCES household_demographics(hd_demo_sk);(ss_item_sk) REFERENCES item(i_item_sk);(ss_promo_sk) REFERENCES promotion(p_promo_sk);(ss_sold_date_sk) REFERENCES date_dim(d_date_sk);(ss_sold_time_sk) REFERENCES time_dim(t_time_sk);(ss_store_sk) REFERENCES store(s_store_sk)");
ALTER TABLE household_demographics SET("foreign_key_constraints" = "(hd_income_band_sk) REFERENCES income_band(ib_income_band_sk)");
ALTER TABLE call_center SET("foreign_key_constraints" = "(cc_closed_date_sk) REFERENCES date_dim(d_date_sk);(cc_open_date_sk) REFERENCES date_dim(d_date_sk)");
ALTER TABLE inventory SET("foreign_key_constraints" = "(inv_date_sk) REFERENCES date_dim(d_date_sk);(inv_item_sk) REFERENCES item(i_item_sk);(inv_warehouse_sk) REFERENCES warehouse(w_warehouse_sk)");
ALTER TABLE web_returns SET("foreign_key_constraints" = "(wr_item_sk) REFERENCES item(i_item_sk);(wr_reason_sk) REFERENCES reason(r_reason_sk);(wr_refunded_addr_sk) REFERENCES customer_address(ca_address_sk);(wr_refunded_cdemo_sk) REFERENCES customer_demographics(cd_demo_sk);(wr_refunded_customer_sk) REFERENCES customer(c_customer_sk);(wr_refunded_hdemo_sk) REFERENCES household_demographics(hd_demo_sk);(wr_returned_date_sk) REFERENCES date_dim(d_date_sk);(wr_returned_time_sk) REFERENCES time_dim(t_time_sk);(wr_returning_addr_sk) REFERENCES customer_address(ca_address_sk);(wr_returning_cdemo_sk) REFERENCES customer_demographics(cd_demo_sk);(wr_returning_customer_sk) REFERENCES customer(c_customer_sk);(wr_returning_hdemo_sk) REFERENCES household_demographics(hd_demo_sk);(wr_web_page_sk) REFERENCES web_page(wp_web_page_sk)");